import React from 'react';
import { Provider } from 'react-redux';
import Home from './common/home.js'
import Detail from './common/detail.js'
import store from './store';
import { BrowserRouter, Route } from 'react-router-dom'

class App extends React.PureComponent {

  render() {
    return (
      <div>
        <Provider store={store}>
          <BrowserRouter>
            <div>
              <Route path='/' exact component={Home} />
              <Route path='/detail/:id' exact component={Detail} />
              <Route path='/home' exact component={Home} />
            </div>
          </BrowserRouter>
        </Provider>
      </div>
    );
  }
}

export default App;